package com.hm.cloud.nacos;

import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

/**
* @Description: TODO
* @param
* @return 
* @throws
* @author Coder编程
* @date 2021/10/12 16:28
*/
@EnableDiscoveryClient
@SpringBootApplication
@RestController
@Slf4j
public class ProviderApplication {

    public static void main(String[] args) {
        SpringApplication.run(ProviderApplication.class, args);
    }

    /**
     * @return
     */
    @GetMapping("/provider")
    public String provider() {
        log.info("服务提供者正常服务");
        return "服务提供者正常服务";
    }


    @GetMapping("/test-feign/{id}")
    public Integer testFeign(@PathVariable(value = "id")Integer id){
        return id+10000;
    }


}